package ve.usb.ddp.hibernate;

import ve.usb.cohesion.runtime.LocalDate;

import ve.usb.cohesion.runtime.LocalDate;

import java.util.HashSet;
import java.util.Set;


public class PaiRemuneracion implements java.io.Serializable, ve.usb.cohesion.runtime.Auditable {

    /** Creates a new instance of PaiRemuneracion */
    public PaiRemuneracion() {}
    
    /**
     * Holds value of property id.
     */
    private Long id;

    /**
     * Getter for property id.
     * @return Value of property id.
     */
    public Long getId() {
        return this.id;
    }

    /**
     * Holds value of property idRemuneracion.
     */
    private long idRemuneracion;

    /**
     * Getter for property idRemuneracion.
     * @return Value of property idRemuneracion.
     */
    public long getIdRemuneracion() {
        return this.idRemuneracion;
    }

    /**
     * Setter for property idRemuneracion.
     * @param idRemuneracion New value of property idRemuneracion.
     */
    public void setIdRemuneracion(long idRemuneracion) {
        this.id = this.idRemuneracion = idRemuneracion;
    }
    /**
     * Holds value of property resolucion.
     */
    private PaiResolucion resolucion;

    /**
     * Getter for property resolucion.
     * @return Value of property resolucion.
     */
    public PaiResolucion getResolucion() {
        return this.resolucion;
    }

    /**
     * Setter for property resolucion.
     * @param resolucion New value of property resolucion.
     */
    public void setResolucion(PaiResolucion resolucion) {
        this.resolucion = resolucion;
    }
    /**
     * Holds value of property concepto.
     */
    private String concepto = "";

    /**
     * Getter for property concepto.
     * @return Value of property concepto.
     */
    public String getConcepto() {
        return this.concepto;
    }

    /**
     * Setter for property concepto.
     * @param concepto New value of property concepto.
     */
    public void setConcepto(String concepto) {
        this.concepto = concepto;
    }
    /**
     * Holds value of property tipo_Financiamiento.
     */
    private String tipo_Financiamiento = "";

    /**
     * Getter for property tipo_Financiamiento.
     * @return Value of property tipo_Financiamiento.
     */
    public String getTipo_Financiamiento() {
        return this.tipo_Financiamiento;
    }

    /**
     * Setter for property tipo_Financiamiento.
     * @param tipo_Financiamiento New value of property tipo_Financiamiento.
     */
    public void setTipo_Financiamiento(String tipo_Financiamiento) {
        this.tipo_Financiamiento = tipo_Financiamiento;
    }
    /**
     * Holds value of property fec_Ini.
     */
    private java.util.Date fec_Ini;

    /**
     * Getter for property fec_Ini.
     * @return Value of property fec_Ini.
     */
    public java.util.Date getFec_Ini() {
        return this.fec_Ini;
    }

    /**
     * Setter for property fec_Ini.
     * @param fec_Ini New value of property fec_Ini.
     */
    public void setFec_Ini(java.util.Date fec_Ini) {
        if (fec_Ini==null || fec_Ini instanceof LocalDate) 
            this.fec_Ini = fec_Ini;
        else this.fec_Ini = new LocalDate(fec_Ini);
    }
    /**
     * Holds value of property fec_Fin.
     */
    private java.util.Date fec_Fin;

    /**
     * Getter for property fec_Fin.
     * @return Value of property fec_Fin.
     */
    public java.util.Date getFec_Fin() {
        return this.fec_Fin;
    }

    /**
     * Setter for property fec_Fin.
     * @param fec_Fin New value of property fec_Fin.
     */
    public void setFec_Fin(java.util.Date fec_Fin) {
        if (fec_Fin==null || fec_Fin instanceof LocalDate) 
            this.fec_Fin = fec_Fin;
        else this.fec_Fin = new LocalDate(fec_Fin);
    }
    /**
     * Holds value of property set_Pago.
     */
    private Set<PaiPago> set_Pago = new HashSet<PaiPago>();

    /**
     * Getter for property set_Pago.
     * @return Value of property set_Pago.
     */
    public Set<PaiPago> getSet_Pago() {
        return this.set_Pago;
    }

    /**
     * Setter for property set_Pago.
     * @param set_Pago New value of property set_Pago.
     */
    public void setSet_Pago(Set<PaiPago> set_Pago) {
        this.set_Pago = set_Pago;
    }

    /**
     * Add an element to set property set_Pago
     * and sets elements's property remuneracion.
     * @param element New element to be added to set_Pago.
     */
    public void addToSet_Pago(PaiPago element) {
        element.setRemuneracion(this);
        set_Pago.add(element);
    }

    /**
     * Removes and old element from set set_Pago 
     * and sets element's property remuneracion to null.
     * @param old The element to be removed from set_Pago
     */
    public void removeFromSet_Pago(PaiPago old) {
        set_Pago.remove(old);
        old.setRemuneracion(null);
    }



    public String toString() {
        return "<PaiRemuneracion id='C" + this.id +
        //idRemuneracion
        ((resolucion==null) ? "" : "\" resolucion =\"C" + resolucion.getId()) +
        "\" concepto =\"" + concepto +
        "\" tipo_Financiamiento =\"" + tipo_Financiamiento +
        "\" fec_Ini =\"" + fec_Ini +
        "\" fec_Fin =\"" + fec_Fin +
        //set_Pago
        "'/>";
    }

}